// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.kpdus.com/jad.html
// Decompiler options: packimports(3) 

package com.nnee.p_pr.p_activity.p_a;

import android.content.Context;
import android.text.Html;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.ImageView;
import android.widget.TextView;
import com.nnee.p_fk.cls_k;
import com.nnee.p_img.cls_c;
import com.nnee.p_img.cls_d;
import com.nnee.p_l.p_b.cls_a;
import com.nnee.p_pr.p_activity.cls_PRISActivitySetting;
import com.nnee.p_pr.p_activity.p_view.TextViewEx;
import com.nnee.p_pr.p_activity.p_view.b;
import com.nnee.p_pr.p_atom.cls_g;
import com.nnee.p_pr.p_atom.cls_u;
import java.util.LinkedList;
import java.util.List;

// Referenced classes of package com.nnee.p_pr.p_activity.a:
//            l, ai, j, k

public class cls_af extends BaseAdapter
{

    public cls_af(Context context)
    {
        h = new cls_l(this);
        f = context;
        g = (LayoutInflater)context.getSystemService("layout_inflater");
        a = com.nnee.p_img.cls_c.a(context, 30F);
        b = a;
        c = com.nnee.p_img.cls_c.a(context, 66F);
        d = c;
    }

    static Context a(af af1)
    {
        return af1.f;
    }

    private void a(cls_ai ai1, View view)
    {
        ai1.b = 0;
        ai1.c = (ImageView)view.findViewById(0x7f0d0107);
        ai1.d = (TextView)view.findViewById(0x7f0d010a);
        ai1.e = (TextView)view.findViewById(0x7f0d010b);
        ai1.f = (TextView)view.findViewById(0x7f0d010c);
        ai1.g = (TextViewEx)view.findViewById(0x7f0d010f);
        ai1.h = (ImageView)view.findViewById(0x7f0d0110);
        ai1.i = (TextView)view.findViewById(0x7f0d0111);
        ai1.j = (TextView)view.findViewById(0x7f0d0112);
        ai1.k = view.findViewById(0x7f0d0017);
_L1:
        return;
        NullPointerException nullpointerexception;
        nullpointerexception;
        nullpointerexception.printStackTrace();
          goto _L1
        Exception exception;
        exception;
        throw exception;
    }

    private void a(cls_ai ai1, cls_u u1, int i)
    {
        int i1;
        ai1.k.setBackgroundDrawable(k.a(f).b(0x7f0200dd));
        String s = u1.aJ();
        ai1.d.setText(s);
        String s1;
        String s2;
        boolean flag;
        String s3;
        String s4;
        StringBuilder stringbuilder1;
        Object aobj[];
        if(u1.aI())
            ai1.e.setText((new StringBuilder()).append("  ").append(f.getString(0x7f0a0078)).toString());
        else
            ai1.e.setText(null);
        s1 = com.nnee.l.b.a.a(f, u1);
        ai1.f.setText(s1);
        if(ai1.b > 0)
        {
            com.nnee.p_img.cls_d.a().a(ai1.b, 1);
            ai1.b = 0;
        }
        ai1.b = com.nnee.p_b.p_a.cls_d.f();
        ai1.c.setImageResource(0x7f020160);
        s2 = u1.aK();
        if(s2 != null)
        {
            StringBuilder stringbuilder = new StringBuilder();
            ai1.c.setTag(stringbuilder);
            com.nnee.p_img.cls_d.a().a(stringbuilder, 1, s2, new cls_j(this, ai1), a, b, 2, ai1.b);
        }
        ai1.h.setVisibility(8);
        ai1.h.setImageDrawable(k.a(f).b(0x7f020055));
        flag = cls_PRISActivitySetting.i(f);
        s3 = u1.b(g.g);
        if(s3 != null && !flag)
        {
            ai1.h.setVisibility(0);
            StringBuilder stringbuilder2 = new StringBuilder();
            ai1.h.setTag(stringbuilder2);
            com.nnee.p_img.cls_d.a().a(stringbuilder2, 2, s3, new com.nnee.p_pr.p_activity.a.k(this, ai1), c, d, 2, ai1.b);
        }
        s4 = u1.X();
        if(s4 == null)
            break MISSING_BLOCK_LABEL_521;
        ai1.a = u1.u();
        if(!ai1.a)
            break MISSING_BLOCK_LABEL_503;
        i1 = k.a(f).c(0x7f0800bb);
_L1:
        if(u1.aI() && u1.aL() != null)
        {
            stringbuilder1 = new StringBuilder();
            aobj = new Object[2];
            aobj[0] = Integer.valueOf(i1);
            aobj[1] = u1.aL();
            s4 = stringbuilder1.append(String.format("<font color='#%06x'><b>%s: </b></font>", aobj)).append(s4).toString();
        }
        ai1.i.setText(null);
        ai1.g.setVisibility(0);
        ai1.g.setText(Html.fromHtml(s4));
        ai1.g.a(h);
        ai1.g.setTag(ai1);
        ai1.g.setTextColor(i1);
        break MISSING_BLOCK_LABEL_563;
        NullPointerException nullpointerexception;
        nullpointerexception;
        nullpointerexception.printStackTrace();
        break MISSING_BLOCK_LABEL_563;
        Exception exception;
        exception;
        throw exception;
        i1 = k.a(f).c(0x7f0800bd);
          goto _L1
        ai1.i.setVisibility(8);
        ai1.g.setVisibility(8);
        ai1.g.setText(null);
        ai1.g.a(null);
        ai1.g.setTag(null);
    }

    public cls_u a(int i)
    {
        cls_u u1;
        if(e != null)
        {
            if(i >= e.size())
                i = -1 + e.size();
            u1 = (u)e.get(i);
        } else
        {
            u1 = null;
        }
        return u1;
    }

    public void a()
    {
        LinkedList linkedlist = e;
        linkedlist;
        JVM INSTR monitorenter ;
        e.clear();
        notifyDataSetChanged();
        return;
    }

    public void a(LinkedList linkedlist)
    {
        e = linkedlist;
    }

    public void a(List list)
    {
        if(list != null && list.size() != 0) goto _L2; else goto _L1
_L1:
        return;
_L2:
        LinkedList linkedlist = e;
        linkedlist;
        JVM INSTR monitorenter ;
        for(int i = -1 + list.size(); i >= 0; i--)
            e.addFirst(list.get(i));

        notifyDataSetChanged();
        if(true) goto _L1; else goto _L3
_L3:
    }

    public void b(List list)
    {
        if(list != null && list.size() != 0) goto _L2; else goto _L1
_L1:
        return;
_L2:
        LinkedList linkedlist = e;
        linkedlist;
        JVM INSTR monitorenter ;
        e.addAll(list);
        notifyDataSetChanged();
        if(true) goto _L1; else goto _L3
_L3:
    }

    public int getCount()
    {
        int i = 0;
        if(e != null)
            i = e.size();
        return i;
    }

    public Object getItem(int i)
    {
        return a(i);
    }

    public long getItemId(int i)
    {
        return (long)i;
    }

    public View getView(int i, View view, ViewGroup viewgroup)
    {
        cls_ai ai1;
        cls_u u1;
        if(view != null && (view.getTag() instanceof cls_ai))
        {
            ai1 = (ai)view.getTag();
        } else
        {
            view = g.inflate(0x7f030047, null);
            ai1 = new cls_ai(this);
            a(ai1, view);
            view.setTag(ai1);
        }
        u1 = a(i);
        if(u1 != null)
            a(ai1, u1, i);
        return view;
    }

    private int a;
    private int b;
    private int c;
    private int d;
    private LinkedList e;
    private Context f;
    private LayoutInflater g;
    private b h;
}
